import service from "@/api/index";
//用户信息管理接口
const USER_INFO_API = "/api/PermissionManagement/";
export default {
	GetLoginUserInfo: (data: any) => {
		//登录
		return service.post(`${USER_INFO_API}GetLoginUserInfo`, data, { headers: { noLoading: true } });
	},
	VerificationUserTel: (data: any) => {
		//验证手机号是否存在
		return service.post(`${USER_INFO_API}VerificationUserTel`, data, { headers: { noLoading: true } });
	},
	AddUserInfo: (data: any) => {
		//新增用户信息
		return service.post(`${USER_INFO_API}AddUserInfo`, data);
	},
	UpdateUserInfo: (data: any) => {
		//更新用户信息
		return service.post(`${USER_INFO_API}UpdateUserInfo`, data);
	},
	ResetUserInfoPassword: (data: any) => {
		//批量/单个重置用户密码
		return service.post(`${USER_INFO_API}ResetUserInfoPassword`, data);
	},
	StatusChangeUserInfo: (data: any) => {
		//批量/单个用户信息状态更改
		return service.post(`${USER_INFO_API}StatusChangeUserInfo`, data);
	},
	GetUserInfo: (data: any) => {
		//根据ID获取用户信息
		return service.post(`${USER_INFO_API}GetUserInfo`, data);
	},
	DeleteUserInfo: (data: any) => {
		//根据ID删除用户信息
		return service.post(`${USER_INFO_API}DeleteUserInfo`, data);
	},
	GetUserInfoListApi: (data: any) => {
		//获取用户列表
		return service.post(`${USER_INFO_API}GetUserInfoListPage`, data);
	},
	LogoutApi: (token: string) => {
		//退出登录
		return service.get(`${USER_INFO_API}Logout?token=` + token);
	}
};
